home *** CD-ROM | disk | FTP | other *** search
/ Technotools / Technotools (Chestnut CD-ROM)(1993).ISO / lang_c / cug191 / delay.asz < prev    next >
Text File  |  1986-05-25  |  2KB  |  76 lines

  1. ;
  2. ;    DELAY.ASM               (Aztec version)                 20 Feb 86
  3. ;
  4. ;   /* ------------------------------------------------------------ */
  5. ;   /*      This is a portion of the SOUND EFFECTS LIBRARY.         */
  6. ;   /*                                                              */
  7. ;   /*      Copyright (C) 1986 by Paul Canniff.                     */
  8. ;   /*      All rights reserved.                                    */
  9. ;   /*                                                              */
  10. ;   /*      This library has been placed into the public domain     */
  11. ;   /*      by the author.  Use is granted for non-commercial       */
  12. ;   /*      pusposes, or as an IMBEDDED PORTION of a commercial     */
  13. ;   /*      product.                                                */
  14. ;   /*                                                              */
  15. ;   /*      Paul Canniff                                            */
  16. ;   /*      PO Box 1056                                             */
  17. ;   /*      Marlton, NJ 08053                                       */
  18. ;   /*                                                              */
  19. ;   /*      CompuServe ID: 73047,3715                               */
  20. ;   /*                                                              */
  21. ;   /* ------------------------------------------------------------ */
  22. ;
  23. ; -------------------------------------------------------------------------
  24. ;    Set up macros for segment values, etc.
  25. ;
  26. ;
  27. codeseg segment para public 'code'
  28. dataseg segment para public 'data'
  29. dummy   DW      0
  30. dataseg ends
  31.     assume cs:codeseg,ds:dataseg,es:dataseg,ss:dataseg
  32. ;
  33. ;
  34. LPROG   EQU     0
  35. ;
  36.     IF    LPROG
  37. ARGS    EQU    6                       ;Bytes on stack before args 
  38.     ELSE
  39. ARGS    EQU    4                       ;Bytes on stack before args
  40.     ENDIF
  41. ;
  42. ; -------------------------------------------------------------------------
  43. ;
  44. ;
  45. CODESEG SEGMENT BYTE PUBLIC 'code'
  46. ;
  47.     PUBLIC    delay_
  48. ;
  49.     IF    LPROG
  50. delay_  PROC   FAR
  51.     ELSE
  52. delay_  PROC   NEAR
  53.     ENDIF
  54.         PUSH    BP
  55.         MOV     BP,SP
  56.         MOV     CX,[BP+ARGS]
  57. OUTLP:  PUSH    CX
  58.         MOV     CX,279
  59. INLP:   LOOP    INLP
  60.         POP     CX
  61.         LOOP    OUTLP
  62.         POP     BP
  63.     RET
  64. delay_  ENDP
  65. ;
  66. ;
  67. codeseg    ends
  68.     END
  69.  
  70.  
  71.  
  72.  
  73.  
  74.  
  75.  
  76.